@badge-prefix: ~"@{prefix}badge";
.@{badge-prefix} {
  position: relative;
  display: inline-block;
  vertical-align: middle;
  line-height: 1;
  &-count {
    position: absolute;
    transform: scale(0);
    top: -10px;
    left: 100%;
    margin-left: -5px;
    border-radius: 100px;
    background: @red-color;
    color: #fff;
    line-height: 18px;
    text-align: center;
    font-size: @font-size-badge;
    white-space: nowrap;
    z-index: 10;
    transition: @transition-time cubic-bezier(0.24, 0.71, 0.73, 1.19);
    min-width: 18px;
    height: 18px;
    padding: 0 4px;

    &-show {
      transform: scale(1);
    }
    &-dot {
      height: 6px;
      width: 6px;
      min-width: 0;
      padding: 0;
      top: -3px;
      left: auto;
      right: -3px;
    }
    a,
    a:hover {
      color: #fff;
    }
    &-alone {
      top: auto;
      display: block;
      position: relative;
      transform: translateX(0);
    }
  }

  &-position-right{
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);

    .@{badge-prefix}-count {
      right: 10px;
      left: auto;
    }
  }
}